//
//  CPYSongListTypeModel.m
//  TTMusic
//
//  Created by chenpengyu on 16/4/5.
//  Copyright © 2016年 cpy. All rights reserved.
//

#import "CPYSongListTypeModel.h"

@implementation CPYSongListTypeModel

- (instancetype)initWithDataSource:(NSDictionary *)dataSource {
    self = [super init];
    if (self) {
        [self setValuesForKeysWithDictionary:dataSource];
        NSMutableArray *mutable = [NSMutableArray array];
        for (NSDictionary *dic in self.children) {
            CPYSongListTypeChildrenModel *childrenModel = [[CPYSongListTypeChildrenModel alloc] init];
            [childrenModel setValuesForKeysWithDictionary:dic];
            [mutable addObject:childrenModel];
        }
        self.children = [NSMutableArray arrayWithArray:mutable];
    }
    return self;
}


@end
